<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>

<!-- 地下车位 -->
<form class="cmxform" id="parkAssort2" method="post"
	action="house/assort/addUnderPark">
	<div style="padding:0px">

		<div class="panel panel-default">
			<div class="panel-heading">
				<h5 class="panel-title">基本信息</h5>
			</div>
			<div class="panel-body">
				<p>
					<span class="style_btn">地下车位总数</span> <span class="style_input"><input
						id="" name="parkNumAll" disabled="disabled" /> 个</span>
				</p>
				<!-- 地下车场start-->
				<div class="style_input" id="dixia">
					<!-- 平面数量start-->
					<p>
						<span class="style_btn">地下车场</span> <span class="style_input">
							<a class="btn btn-danger radius a_font" id="addUnPark"
							onclick="addUnderDiv()"> 添加</a>
						</span>
					</p>
				</div>
				<!-- 地下车场end-->
				<!-- 人防车场start-->
				<div class="style_input" id="renfang">
					<!-- 平面数量start-->
					<p>
						<span class="style_btn">人防车场</span> <span class="style_input">
							<a class="btn btn-danger radius a_font" id="addRFpark"
							onclick="addRfDiv()"> 添加</a>
						</span>
					</p>
				</div>
				<!-- 人防车场end-->
			</div>
		</div>
		<div style="width:100%;text-align:center; padding-top:20px">
			<div id="btn_div1">
				<button class="btn btn-danger radius my-btn"
					onclick="saveParkAssort2(0)" type="button">提交</button>
				<button class="btn btn-danger radius my-btn"
					onclick="saveParkAssort2(1)" type="button">保 存</button>
				<a class="btn btn-default radius"
					onClick="resetForms('parkAssort2');"> 重置 </a> <br />
			</div>
			<div id="btn_div2" style="display:none;">
				<shiro:hasPermission name="permission:edit">
					<button id="modifyBtn" type="button"
						class="btn btn-danger radius my-btn" onclick="saveParkAssort2(3)">启用编辑</button>
					<button class="btn btn-danger radius my-btn hidbtn"
						onclick="saveParkAssort2(2)" type="button">保存修改</button>
					<a class="btn btn-default radius hidbtn"
						onClick="resetForms('parkAssort2');">重置</a>
				</shiro:hasPermission>
			</div>
		</div>
		<input type="hidden" name="parkSite" id="entityId_parkSite" value="1" />
		<!-- 模板div start -->
		<div id="underPark" style="display:none;">
			<div style="border:1px solid gray;padding:10px;margin:10px 0px;"
				class="underParkMsg">
				<div>
					<p>
						<span class="style_btn">楼&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;层</span>
						<span class="style_input"><input id="" name="parkFloor" />
							层</span><input hidden="hidden" name="parkId" id="entityId_parkId"><input
							hidden="hidden" name="parkType" value="0" id="entityId_underType"><span
							style="    float: right;"> <a href="javascript:void(0)"
							onclick="delUnderDiv(this)"> <i class="icon-fullscreen"></i>
						</a></span>
					</p>
					<p>
						<span class="style_btn">平面车位</span> <span class="style_input"><input
							id="" name="parkPlaneNum" onkeyup="changeParkAllNum()"/> 个</span>
					</p>
					<div style="border:1px solid gray;padding:10px;margin:10px 0px;">
						<table cellpadding="10" cellspacing="5" class="mytable" id="plane">
							
							<tr>
								<td width="40" class="td-right"><span>租赁</span></td>
								<td width="260"><input id="" name="leaseNum" value="" /> 个<input type="hidden" name="id" id="entityId_ppnIds" />
								</td>
								<td width="60" class="td-right"><span>单价</span></td>
								<td colspan="3"><input id="" name="leasePrice" value="" />
								<select name="priceType_p"   style="width:70px">
										<option value="0">元/月</option>
										<option value="1">元/年</option>
								</select></td>
							</tr>
							<tr>
								<td rowspan="2" class="td-right"><span>临停</span></td>
								<td rowspan="2"><input id="" name="tempStopNum" value="" /> 个</td>
								<td class="td-right"><span>日范围</span></td>
								<td><input id="" name="tempStopRange" value="" /></td>
								<td width="60" class="td-right"><span>日单价</span></td>
								<td><input id="" name="tempStopPrice" value="" /> 元/时</td>
							</tr>
							<tr>
								
								<td class="td-right"><span>夜范围</span></td>
								<td><input id="" name="tempStopRangeNight" value="" /></td>
								<td class="td-right"><span>夜单价</span></td>
								<td><input id="" name="tempStopPriceNight" value="" /> 元/时</td>
							</tr>
						</table>
					</div>
					<!-- 平面数量start-->
					<!-- 立体数量start-->
					<div id="litiNum">
						<p>
							<span class="style_btn">立体车位</span> <span class="style_input"><input
								id="" name="parkSolidNum" value="" onkeyup="changeParkAllNum()"/></span>
						</p>
						<div style="border:1px solid gray;padding:10px;">
							<table cellpadding="10" cellspacing="5" class="mytable"
								id="solid">
								<tr>
									<td width="40" class="td-right"><span>销售</span></td>
									<td colspan="5"><input id="" name="marketNum" value="" />
										个<input type="hidden" name="id" id="entityId_psnIds" /></td>
								</tr>
								<tr>
									<td width="40" class="td-right"><span>租赁</span></td>
									<td width="260"><input id="" name="leaseNum" value="" />
										个</td>
									<td width="60" class="td-right"><span>单价</span></td>
									<td colspan="3"><input id="" name="leasePrice" value="" />
									<select name="priceType_s"  style="width:70px">
										<option value="0">元/月</option>
										<option value="1">元/年</option>
								</select></td>
								</tr>
								<tr>
									<td rowspan="2" class="td-right"><span>临停</span></td>
									<td rowspan="2"><input id="" name="tempStopNum" value="" /> 个</td>
									<td class="td-right"><span>日范围</span></td>
									<td><input id="" name="tempStopRange" value="" /></td>
									<td width="60" class="td-right"><span>日单价</span></td>
									<td><input id="" name="tempStopPrice" value="" /> 元/时</td>
								</tr>
								<tr>
									
									<td class="td-right"><span>夜范围</span></td>
									<td><input id="" name="tempStopRangeNight" value="" /></td>
									<td class="td-right"><span>夜单价</span></td>
									<td><input id="" name="tempStopPriceNight" value="" /> 元/时</td>
								</tr>
							</table>
						</div>
					</div>
				</div>
				<!-- 立体数量end-->

			</div>
		</div>
		<!-- 地下车场模板end -->
		<!-- 人防车场模板start -->
		<div id="rfPark" style="display:none;">
			<div style="border:1px solid gray;padding:10px;margin:10px 0px;"
				class="rfParkMsg">
				<div>
					<!-- 平面数量start-->
					<p>
						<span class="style_btn">楼层</span> 
							<span class="style_input">
							<input id="parkFloor" name="parkFloor" />层</span>
							<span style="float: right;"> 
						</span>
					</p>
					<p>
						<span class="style_btn">平面车位</span> <span class="style_input"><input
							id="" name="parkPlaneNum"  onkeyup="changeParkAllNum()"/> 个<input hidden="hidden"
							name="parkId" id="entityId_parkId"><input hidden="hidden" name="parkType"
							value="1" id="entityId_parkType"></span><span style="float: right;"> <a
							href="javascript:void(0)" onclick="delUnderDiv(this)"> <i
								class="icon-fullscreen"></i>
						</a></span>
					</p>
					<div style="border:1px solid gray;padding:10px;margin:10px 0px;">
						<table cellpadding="10" cellspacing="5" class="mytable" id="plane">
							
							<tr>
								<td width="40" class="td-right"><span>租赁</span></td>
								<td width="250"><input id="" name="leaseNum" value="" /> 个<input type="hidden" name="id" id="entityId_pguIds" />
								</td>
								<td width="60" class="td-right"><span>单价</span></td>
								<td colspan="3"><input id="" name="leasePrice" value="" />
								<select name="priceType_p"  style="width:70px">
										<option value="0">元/月</option>
										<option value="1">元/年</option>
								</select></td>
							</tr>
							<tr>
								<td rowspan="2" class="td-right"><span>临停</span></td>
								<td rowspan="2"><input id="" name="tempStopNum" value="" /> 个</td>
								<td class="td-right"><span>日范围</span></td>
								<td><input id="" name="tempStopRange" value="" /></td>
								<td class="td-right"><span>日单价</span></td>
								<td><input id="" name="tempStopPrice" value="" /> 元/时</td>
							</tr>
							<tr>
								
								<td class="td-right"><span>夜范围</span></td>
								<td><input id="" name="tempStopRangeNight" value="" /></td>
								<td class="td-right"><span>夜单价</span></td>
								<td><input id="" name="tempStopPriceNight" value="" /> 元/时</td>
							</tr>
						</table>
					</div>
					<!-- 平面数量end-->
				</div>
				<!-- 人防车场模板end -->
			</div>
		</div>
	</div>
</form>
<script type="text/javascript">
	//存储将要删除的id，传到后台删除
	var delParkIds = new Array();
	$(document).ready(function() {
		//$("#parkType").select2();
		mySubmit("parkAssort2", initPark2, successPark2);
		getParkAssort2Msg();
		
	});
	//计算车位总数
	function changeParkAllNum(){
		var parkAllNum=0;
		var parkPlaneList=$("#parkAssort2 input[name='parkPlaneNum']");
		var parkSolidList=$("#parkAssort2 input[name='parkSolidNum']");
		$.each(parkPlaneList,function(index,value){
			var a=$(value).val();
			if(a==""||!testNum(a)){
				a=0;
			}
			parkAllNum=parseInt(a)+parseInt(parkAllNum);
		})
		$.each(parkSolidList,function(index,value){
			var a=$(value).val();
			if(a==""||!testNum(a)){
				a=0;
			}
			parkAllNum=parseInt(a)+parseInt(parkAllNum);
		})
		$("#parkAssort2 [name='parkNumAll']").val(parkAllNum); 
	}

	//获取编辑页面数据
	function getParkAssort2Msg() {
		var fkProjectid = parent.parent.parent.projectID;
		var parkSite = $("#parkAssort2 input[name='parkSite']").val();
		var url = "house/assort/getParkAssortByBuild";
		$.getJSON(url, {
			fkProjectId : fkProjectid,
			parkSite : parkSite
		}, function(data, status) {
			if (data.length > 0) {
				var parkNumAll = 0;
				var dixia = new Array(); //地下车场
				var renfang = new Array(); //人防车场
				$.each(data, function(a, obj) {
					if (obj.parkType == "0") {
						addUnderDiv();
						dixia.push(obj);
					} else {
						addRfDiv();
						renfang.push(obj);
					}
				});
				var under = $("#dixia").find(".underParkMsg");
				for (var i = 0; i < under.length; i++) {
					insertMsg(under[i], dixia[i]);
					parkNumAll += dixia[i].parkNum;
				}
				var rf = $("#renfang").find(".rfParkMsg");
				for (var i = 0; i < rf.length; i++) {
					insertMsg(rf[i], renfang[i]);
					parkNumAll += renfang[i].parkNum;
				}
				$("#parkAssort2").find("input[name='parkNumAll']").val(parkNumAll);
				$("#parkAssort2").find("#btn_div2").show();
				$("#parkAssort2").find("#btn_div1").hide();
				$("#parkAssort2 .icon-fullscreen").hide();
				$("#parkAssort2").find("input,textarea").attr("readonly", true);
				$("#parkAssort2").find("#addUnPark,#addRFpark,select").attr("disabled", true);

			} else {
				$("#parkAssort2").find("#btn_div2").hide();
				$("#parkAssort2").find("#btn_div1").show();
			}
		});
	}
	//填充编辑页面数据
	function insertMsg($park, data) {
		$park = $($park);
		$park.find("input[name='parkId']").val(data.parkId);
		$park.find("input[name='parkFloor']").val(data.parkFloor);
		$park.find("input[name='parkPlaneNum']").val(data.planeNum);
		$park.find("input[name='parkSolidNum']").val(data.solidNum);
		$park.find("#plane input[name='leaseNum']").val(data.pLeaseNum);
		$park.find("#plane input[name='leasePrice']").val(returnFloat(data.pLeasePrice));
		$park.find("#plane input[name='tempStopNum']").val(data.pTempNum);
		$park.find("#plane input[name='tempStopPrice']").val(returnFloat(data.pTempPrice));
		$park.find("#plane input[name='tempStopPriceNight']").val(returnFloat(data.nightPrice));
		$park.find("#plane input[name='tempStopRange']").val(data.pTempStopRange);
		$park.find("#plane input[name='tempStopRangeNight']").val(data.pTempStopRangeNight);
		$park.find("#plane input[name='id']").val(data.pId);
		$park.find("#plane select[name='priceType_p']").val(data.ppriceType).trigger("change");
		$park.find("#solid input[name='marketNum']").val(data.sMarketNum);
		$park.find("#solid input[name='leaseNum']").val(data.sLeaseNum);
		$park.find("#solid input[name='leasePrice']").val(returnFloat(data.sLeasePrice));
		$park.find("#solid input[name='tempStopNum']").val(data.sTempNum);
		$park.find("#solid input[name='tempStopPrice']").val(returnFloat(data.sTempPrice));
		$park.find("#solid input[name='tempStopPriceNight']").val(returnFloat(data.solidNightPrice));
		$park.find("#solid input[name='tempStopRange']").val(data.sTempStopRange);
		$park.find("#solid input[name='tempStopRangeNight']").val(data.sTempStopRangeNight);
		$park.find("#solid select[name='priceType_s']").val(data.spriceType).trigger("change");
		$park.find("#solid input[name='id']").val(data.sId);

	}
	var optParkAssort2;
	//optParkAssort2操作字段，0：临时保存；1：新增；2：修改
	function saveParkAssort2(val) {
		optParkAssort2 = val;
		if (val == 3) {
			//解除锁定状态
			var index = layer.confirm('确定开启编辑状态？', {
				offset : '20%',
				shade : 0
			}, function() {
				//去除只读开启按钮编辑
				$("#parkAssort2").find("input,textarea").attr("readonly", false);
				$("#parkAssort2").find("#modifyBtn").hide();
				// $(".hidbtn").removeClass("hidbtn");
				$("#parkAssort2 .icon-fullscreen").show();
				$("#parkAssort2").find(".hidbtn").addClass("showbtn");
				$("#parkAssort2").find("select").removeAttr("disabled");
				$("#parkAssort2").find("#addUnPark,#addRFpark,select").attr("disabled", false);
				layer.close(index);
			});
		} else {

			$("#parkAssort2").submit();
		}
	}

	/* $("#parkType").change(function() {
		var val = $(this).val();
		if (val == "1") {
			$("#litiNum").hide();
			//清空数据
			$("#litiNum input").val("");
		} else {
			$("#litiNum").show();
		}
	}); */

	//封装表单数据为json
	function initPark2() {
		layer.load(2);
		var parkList = [];
		var flag = false;
		var a;
		var b;
		//封装地下车场数据
		var underMsg = $("#dixia").find(".underParkMsg");
		if (underMsg.length > 0) {
			for (var i = 0; i < underMsg.length; i++) {
				a = packageParkMsg(underMsg[i]);
				if (a == null) {
					return null;

				} else {
					parkList.push(a);
				}

			}
		}
		//封装人防车场数据
		var renfangMsg = $("#renfang").find(".rfParkMsg");
		if (renfangMsg.length > 0) {
			for (var i = 0; i < renfangMsg.length; i++) {
				b = packageParkMsg(renfangMsg[i]);
				if (b == null) {
					return null;

				} else {
					parkList.push(b);
				}
			}
		}
		
		
		return {
			opt:optParkAssort2,
			delIds:delParkIds,
			parklist:parkList
		};

	}
	var x;//load弹窗index
	//封装数据
	function packageParkMsg($park) {
		x=layer.load(2);
		$park = $($park);
		//封装基础数据
		var fkProjectid = parent.parent.parent.projectID;
		var parkSite = $("#parkAssort2 input[name='parkSite']").val();
		var parkPlaneNum = $park.find("input[name='parkPlaneNum']").val();
		var parkSolidNum = $park.find("input[name='parkSolidNum']").val();
		var parkType = $park.find("input[name='parkType']").val();
		var parkFloor = $park.find("input[name='parkFloor']").val();
		var parkId = $park.find("input[name='parkId']").val();
		var parkNum;
		if (parkType == "1") {
			parkNum = parkPlaneNum;
		} else {
			parkNum = parseInt(parkPlaneNum) + parseInt(parkSolidNum);
		}

		//封装平面数据
		var $t = $park.find("table:eq(0)");
		var plane = new Array();
		var planeNumSum = 0;//平面车位总数
		for (var i = 0; i < $t.length; i++) {
			var v = $t[i];
			var pId = $(v).find("input[name='id']").val();
			//var marketNum = $(v).find("input[name='marketNum']").val();
			var leaseNum = $(v).find("input[name='leaseNum']").val();
			var leasePrice = $(v).find("input[name='leasePrice']").val();
			var tempStopNum = $(v).find("input[name='tempStopNum']").val();
			var tempStopPrice = $(v).find("input[name='tempStopPrice']").val();
			var priceType = $(v).find("select[name='priceType_p']").val();
			var tempStopPriceNight = $(v).find("input[name='tempStopPriceNight']").val();
			var tempStopRange = $(v).find("input[name='tempStopRange']").val();
			var tempStopRangeNight = $(v).find("input[name='tempStopRangeNight']").val();
			if (!testNum(leaseNum)) {
				layer.msg("平面车位中租赁个数请输入数值");
				$(v).find("input[name='leaseNum']").focus();
				layer.close(x);
				return null;
			} else if (!testNum(leasePrice)) {
				layer.msg("平面车位中租赁单价请输入数值");
				$(v).find("input[name='leasePrice']").focus();
				layer.close(x);
				return null;
			} else if (!testNum(tempStopNum)) {
				layer.msg("平面车位中临停个数请输入数值");
				$(v).find("input[name='tempStopNum']").focus();
				layer.close(x);
				return null;
			} else if (!testNum(tempStopPrice)) {
				layer.msg("平面车位中临停日单价请输入数值");
				$(v).find("input[name='tempStopPrice']").focus();
				layer.close(x);
				return null;
			}else if (!testNum(tempStopPriceNight)) {
				layer.msg("平面车位中临停夜单价请输入数值");
				$(v).find("input[name='tempStopPriceNight']").focus();
				layer.close(x);
				return null;
			}
			planeNumSum =parseInt(leaseNum)+parseInt(tempStopNum);//平面车位总数=租赁车位数+临停车位数
			plane.push({
				id : pId,
				marketNum : 0,
				leaseNum : leaseNum,
				leasePrice : leasePrice,
				tempStopNum : tempStopNum,
				tempStopPrice : tempStopPrice,
				fkProjectid : fkProjectid,
				priceType:priceType,
				tempStopPriceNight:tempStopPriceNight,
				tempStopRangeNight:tempStopRangeNight,
				tempStopRange:tempStopRange
			});
		}
		if (parkType == "0") {
			var solidNumSum=0;//立体车位数
			//封装立体数据
			var $t = $park.find("#litiNum table");
			var solid = new Array();
			for (var i = 0; i < $t.length; i++) {
				var v = $t[i];
				var sId = $(v).find("input[name='id']").val();
				var marketNum = $(v).find("input[name='marketNum']").val();
				var leaseNum = $(v).find("input[name='leaseNum']").val();
				var leasePrice = $(v).find("input[name='leasePrice']").val();
				var tempStopNum = $(v).find("input[name='tempStopNum']").val();
				var tempStopPrice = $(v).find("input[name='tempStopPrice']").val();
				var priceType = $(v).find("select[name='priceType_s']").val();
				var tempStopPriceNight = $(v).find("input[name='tempStopPriceNight']").val();
				var tempStopRange = $(v).find("input[name='tempStopRange']").val();
				var tempStopRangeNight = $(v).find("input[name='tempStopRangeNight']").val();
				if (!testNum(marketNum)) {
					layer.msg("立体车位中销售个数请输入数值");
					$(v).find("input[name='marketNum']").focus();
					layer.close(x);
					return null;
				} else if (!testNum(leaseNum)) {
					layer.msg("立体车位中租赁个数请输入数值");
					$(v).find("input[name='leaseNum']").focus();
					layer.close(x);
					return null;
				} else if (!testNum(leasePrice)) {
					layer.msg("立体车位中租赁单价请输入数值");
					$(v).find("input[name='leasePrice']").focus();
					layer.close(x);
					return null;
				} else if (!testNum(tempStopNum)) {
					layer.msg("立体车位中临停个数请输入数值");
					$(v).find("input[name='tempStopNum']").focus();
					layer.close(x);
					return null;
				} else if (!testNum(tempStopPrice)) {
					layer.msg("立体车位中临停日单价请输入数值");
					$(v).find("input[name='tempStopPrice']").focus();
					layer.close(x);
					return null;
				}else if (!testNum(tempStopPriceNight)) {
					layer.msg("平面车位中临停夜单价请输入数值");
					$(v).find("input[name='tempStopPriceNight']").focus();
					layer.close(x);
					return null;
				}
				solidNumSum =parseInt(marketNum)+parseInt(leaseNum)+parseInt(tempStopNum);//立体车位总数=销售车位数+租赁车位数+临停车位数
				solid.push({
					id : sId,
					marketNum : marketNum,
					leaseNum : leaseNum,
					leasePrice : leasePrice,
					tempStopNum : tempStopNum,
					tempStopPrice : tempStopPrice,
					priceType:priceType,
					tempStopPriceNight:tempStopPriceNight,
					tempStopRangeNight:tempStopRangeNight,
					tempStopRange:tempStopRange
				});
			}
		}
		if (!testNum(parkPlaneNum)) {
			layer.msg("平面车位请输入数值");
			$park.find("input[name='parkPlaneNum']").focus();
			layer.close(x);
			return null;
		}
		//物业录的数据尚不完善，暂时先注释掉,后期数据完善后再添加该功能，切记勿删！！！！！！！！
		/* else if (parkPlaneNum<planeNumSum) {
			layer.msg("平面车位总数不能小于平面销售、租赁、临停车位总和");
			$park.find("input[name='parkPlaneNum']").focus();
			layer.close(x);
			return null;
		}  */
		else {
			if (parkType == "0") {
				if (!testNum(parkSolidNum)) {
					layer.msg("立体车位请输入数值");
					$park.find("input[name='parkSolidNum']").focus();
					layer.close(x);
					return null;
				}
				//物业录的数据尚不完善，暂时先注释掉,后期数据完善后再添加该功能，切记勿删！！！！！！！！
				/* else if (parkSolidNum<solidNumSum) {
					layer.msg("立体车位总数不能小于立体销售、租赁、临停车位总和");
					$park.find("input[name='parkSolidNum']").focus();
					layer.close(x);
					return null;
				} */ 
				else {
					return {
						id : parkId,
						parkNum : parkNum,
						fkProjectid : fkProjectid,
						parkSite : parkSite,
						parkPlaneNum : parkPlaneNum,
						parkSolidNum : parkSolidNum,
						parkType : parkType,
						parkFloor : parkFloor,
						parkPlaneFk2 : plane,
						parkSolidFk2 : solid,
						
					};
				}

			} else {
				return {
					id : parkId,
					parkNum : parkNum,
					fkProjectid : fkProjectid,
					parkSite : parkSite,
					parkPlaneNum : parkPlaneNum,
					parkType : parkType,
					parkFloor : parkFloor,
					parkPlaneFk2 : plane,
				};
			}
		}
	}
	//成功后调用方法
	function successPark2(responseText) {
		delParkIds = new Array();
		if (responseText.success) {
			 layer.alert("保存成功！",{
				offset:'20%',
				shade:[0.1,'#fff']
			},function(){
				getParkAssort2Msg();
				$("#parkAssort2").find("#modifyBtn").show();
				$("#parkAssort2").find(".hidbtn").removeClass("showbtn");
				$("#parkAssort2 #dixia>div").remove();
				$("#parkAssort2 #renfang>div").remove(); 
				layer.closeAll();
			});
			layer.close(x);
			
		} else {
			layer.alert('保存失败！');
			layer.close(x);
		}
	}
	//添加地下车场
	function addUnderDiv() {
		var node = $("#underPark").html();
		var oTest = $("#dixia");
		oTest.append(node);
		$("#dixia").find("select[name='priceType_p']").select2();
		$("#dixia").find("select[name='priceType_s']").select2();
	}
	//添加人防车场
	function addRfDiv() {
		var node = $("#rfPark").html();
		var oTest = $("#renfang");
		oTest.append(node);
		$("#renfang").find("select[name='priceType_p']").select2();
	}
	
	function delUnderDiv(obj) {
		var aId = $(obj).parent().parent().find("input[name='parkId']").val();
		delParkIds.push(aId);
		$(obj).parent().parent().parent().parent().remove();
		layer.msg("点击保存后，将彻底删除该条数据！");
		//重新计算总车位数量
		changeParkAllNum();
	}

</script>


